package threadlocal;

public class Transfer2 implements Runnable {
    private Bank bank;

    public Transfer2(Bank bank) {
        this.bank = bank;
    }

    @Override
    public void run() {
        for (int i = 0; i < 5; i++) {
            bank.setInteger();
            System.out.println(Thread.currentThread().getName() + "..." + bank.getInteger());
        }
    }
}
